import request from "@/utils/request";

// 消息列表
export const messageList = (params) =>
  request({
    baseURL: window.APP_GETEWAY.message,
    url: "/message/user/message",
    method: "get",
    params,
  });

// 消息详情
export const messageDetails = (params) =>
  request({
    baseURL: window.APP_GETEWAY.message,
    url: `/message/user/message/${params.id}`,
    method: "get",
  });
// 标记消息
export const messageView = (data) =>
  request({
    baseURL: window.APP_GETEWAY.message,
    url: `/message/user/message/view`,
    method: "POST",
    data,
  });
//弹窗消息列表
export const messagePop = () =>
  request({
    baseURL: window.APP_GETEWAY.message,
    url: `/message/user/message/pop`,
    method: "get",
  });

//未读消息统计
export const messageUnView = () =>
  request({
    baseURL: window.APP_GETEWAY.message,
    url: `/message/user/message/unView`,
    method: "get",
  });

//文件下载message
export const downFlieMsg = (params) =>
  request({
    baseURL: window.APP_GETEWAY.message,
    url: "/message/storage/signUrl",
    method: "get",
    params,
  });
